const path = require('path');
const webpack = require('webpack');
const componentName = "reports-desktop";
const HtmlWebPackPlugin = require('html-webpack-plugin');
module.exports = {
    entry: './src/index.js',
    resolve: {
        extensions: ['*', '.js', '.json', '.jsx']
    },
    devServer: {
        contentBase: path.join(__dirname, './src')
    },
    module: {
        rules: [
            {
                test: /\.js$/,
                exclude: /node_modules/,
                use: {
                    loader: "babel-loader"
                }
            }
        ]
    },
    plugins: [
        new webpack.IgnorePlugin(/^\.\/locale$/, /moment$/),
        new HtmlWebPackPlugin({
            template: 'public/index.html',
            filename: 'index.html',
            inject: true
        })

    ]
};